package code17_reflect;

//@MyAnn01("xxx")
// 多个值赋值时, 不能省略 value=
@MyAnn01(value="Person", age=30)
public class Person {
	@Value("pId")
	public int id;
	@Value("sex")
	private String sex;
	
	public void sleep() {
		System.out.println("Person.sleep()");
	}
	private void eat() {
		System.out.println("Person.eat()");
	}
	@Override
	public String toString() {
		return "Person [id=" + id + ", sex=" + sex + "]";
	}
}
